//Component.java
package prototype.record;
import java.io.Serializable;
import java.util.*;

/**
 * This class's object is one of the ConcretePrototype class's
 * attribute.
 * Note:Log class must implement Serializable interface for deep clone
 * in ConcretePrototype.clone() function
 *@author:youtubezou
 *@version:2012-7-16
 */
public class Log implements Serializable{
	private static final long serialVersionUID = 7749844669260519391L;
	private String info;
	private Date time;
	
	public static void main(String[] args){
		System.out.println(new Log("Tony"));
	}
	
	
	public Log(String info){
		this.info = info;
		time = new Date();
	}
	
	public void setTime(){
		time = new Date();
	}
	
	public String toString(){
		return "\tinfo:" + "\t" + info + "\n" +
				"\ttime:" + "\t" + time;
	}

}
